package com.yuyou.activity.comm.service.service;


import com.yuyou.activity.comm.service.entity.CommSmsVerCode;
import com.yuyou.activity.util.bean.ResBoolSimpleInfo;

public interface ICommSmsVerCodeService {
    int deleteByPrimaryKey(String id);

    int insert(CommSmsVerCode record);

    CommSmsVerCode selectByPrimaryKey(String id);

    int updateByPrimaryKeySelective(CommSmsVerCode record);
    
    CommSmsVerCode selectLastByMobile(String mobile);

    CommSmsVerCode selectLastByMobileAndType(String mobile, String type);

    CommSmsVerCode selectLastByMobileAndTypeAndCode(String mobile, String type, String code);

    /**
     * 发送短信验证码
     * @param mobile
     * @param type
     * @return
     */
    ResBoolSimpleInfo<String> addSmsVerCode(String mobile, String type);

    /**
     * 验证手机验证码
     * @param mobile
     * @param verCode
     * @return
     */
    ResBoolSimpleInfo<String> verSmS(String mobile, String verCode);
    
    
}